package com.company;

import java.util.ArrayList;

/**
 * @description:
 * @author: 10445
 * @date: Created in 2020/6/8 17:55
 * @version: v1.0
 * @modified By:
 */
public class MonsterWolfSet {
    private ArrayList<MonsterWolf> monsterWolves = new ArrayList<>();


    //增删改查
    //根据名称找对象
    public MonsterWolf get(String id){
        MonsterWolf monsterWolf = null;
        for (MonsterWolf item:monsterWolves
             ) {
            if (true==id.equals(item.getId())){
                monsterWolf=item;
                break;
            }
        }
        return monsterWolf;
    }

    public MonsterWolfSet() {
    }

    public MonsterWolfSet(ArrayList<MonsterWolf> monsterWolves) {
        this.monsterWolves = monsterWolves;
    }

    public ArrayList<MonsterWolf> getMonsterWolves() {
        return monsterWolves;
    }

    public void setMonsterWolves(ArrayList<MonsterWolf> monsterWolves) {
        this.monsterWolves = monsterWolves;
    }
}
